package com.ciaojian.core.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;

/**
 * @author oxiny
 */
@EqualsAndHashCode(callSuper = true)
@Data
@TableName("d_worker_service")
public class WorkerService extends Model<WorkerService> {
    @TableId(type = IdType.AUTO)
    private Integer id;

    private Integer workerId;

    private Integer serviceId;

    private Integer price;


    @JsonFormat(pattern="yyyy-MM-dd", timezone = "GMT+8")
    private Date addTime;

    @JsonFormat(pattern="yyyy-MM-dd", timezone = "GMT+8")
    private Date updateTime;

    private Integer commission;

    @TableField(exist = false)
    private String serviceName;

}
